export default(state)=>({
  getSystemInfo(){ // 获取窗口数据
    state.system = {
      ...state.system,
      ...wx.getAccountInfoSync().miniProgram
    }
    uni.getSystemInfo({
      success:function(e) {
        let { top , height} = uni.getMenuButtonBoundingClientRect()
        state.style.headerHeight = top * 2 + height - e.statusBarHeight // 头部高度
        state.style.statusBarHeight = e.statusBarHeight // 状态条高度
        state.style.ruler = e.windowWidth / 750 // px对rpx比例
      }
    })
  }
})
